package TEST;


import static org.junit.Assert.*;
import org.junit.Before;
import org.junit.Test;
import shared.Messages.BeginMessage;

public class BeginMessageTest {
	BeginMessage m1;
	BeginMessage m2;
	
	@Before
	public void setUp() throws Exception {
		m1 = new BeginMessage(10,"Mangija1","Mangija2",1,2);
		m2 = new BeginMessage(33,"Ants","Mati",12,21);
	}
	
	@Test
	public void GameNoTest(){
		assertEquals(10,m1.GameNo);
		assertEquals(33,m2.GameNo);
	}
	
	@Test
	public void PlayerNameTest(){
		assertEquals("Mangija1",m1.name1);
		assertEquals("Mangija2",m1.name2);
		assertEquals("Ants",m2.name1);
		assertEquals("Mati",m2.name2);
	}
	
	@Test
	public void PlayerIDTest(){
		assertEquals(1,m1.playerId1);
		assertEquals(2,m1.playerId2);
		assertEquals(12,m2.playerId1);
		assertEquals(21,m2.playerId2);
	}

}
